package com.springboot.shiro.mapper;

import com.springboot.shiro.pojo.User;
import org.apache.ibatis.annotations.Param;

public interface UserMapper {
    int deleteByPrimaryKey(Integer uid);

    int insert(User record);

    int insertSelective(User record);

    User selectByPrimaryKey(Integer uid);

    int updateByPrimaryKeySelective(User record);

    int updateByPrimaryKey(User record);

    /**
     * 通过用户名查询实体
     *
     * @param username
     * @return
     */
    User findByUserName(@Param("username") String username);

    /**
     * 根据用户名删除用户信息
     *
     * @param userName
     * @return
     */
    Integer deleteByUserName(@Param("username") String userName);

}